<div ng-controller="FileCtrl">
  <ol class="breadcrumb">
    <li><a href="/">datahub</a> <span class="divider">/</span></li>
    <li><a href="/#/data/">data</a> <span class="divider">/</span></li>
    <li class="active">{{path}}</li>
  </ol>
  <hr>
  <div>
    <form>
      <table class="table table-striped">
        <thead>
          <tr>
            <th>Path</th>
            <th>Contents</th>
            <th>Actions</th>
        </thead>
        <tbody>
          <tr ng-repeat="(key,val) in dir">
            <td><a href="#/data{{key}}">/data{{key}}</a></td>
            <td>
              <ul>
                <li ng-repeat="(key,val) in val">{{key}}:{{val}}</li>
              </ul>
            </td>
            <td>
              <button ng-click="delete(key)" class="btn"><i class="icon-trash"></i> Delete</button>
            </td>
          </tr>
        </tbody>
      </table>
    </form>
  </div>
  <hr>
  <button type="button" class="btn" data-toggle="collapse" data-target="#createButton">
    Create
  </button>
  <div id="createButton" class="collapse">
    <hr>
    <div class="input-prepend">
      <span class="add-on">Name (optional):</span>
      <input ng-model="id" class="span2" type="text">
    </div>
<textarea id="object" rows="5" cols="20">{
  "text":"Hello World!",
  "count":10
}</textarea><br/>
    <button ng-click="save()" class="btn btn-primary">Save</button>
  </div>
</div>
